
package com.caration.shell;

import android.net.Uri;
import android.provider.BaseColumns;

class DatabaseStruct {
    static interface BaseShellColumns extends BaseColumns {
        /**
         * Primary Key
         * <P>
         * Type: INTEGER
         * </P>
         */
        static final String ID = "_id";
    }

    static final class Favorites implements BaseShellColumns {

        /**
         * The content:// style URL for this table
         */
        static final Uri CONTENT_URI = Uri.parse("content://" + ShellProvider.AUTHORITY + "/"
                + ShellProvider.TABLE_FAVORITES + "?" + ShellProvider.PARAMETER_NOTIFY + "=true");

        /**
         * The content:// style URL for this table. When this Uri is used, no
         * notification is sent if the content changes.
         */
        static final Uri CONTENT_URI_NO_NOTIFICATION = Uri.parse("content://"
                + ShellProvider.AUTHORITY + "/" + ShellProvider.TABLE_FAVORITES + "?"
                + ShellProvider.PARAMETER_NOTIFY + "=false");

        /**
         * The content:// style URL for a given row, identified by its id.
         * 
         * @param id The row id.
         * @param notify True to send a notification is the content changes.
         * @return The unique content URL for the specified row.
         */
        static Uri getContentUri(long id, boolean notify) {
            return Uri.parse("content://" + ShellProvider.AUTHORITY + "/"
                    + ShellProvider.TABLE_FAVORITES + "/" + id + "?"
                    + ShellProvider.PARAMETER_NOTIFY + "=" + notify);
        }

        /**
         * Descriptive name of the gesture that can be displayed to the user.
         * <P>
         * Type: TEXT
         * </P>
         */
        static final String TITLE = "title";

        /**
         * The Intent URL of the gesture, describing what it points to. This
         * value is given to
         * {@link android.content.Intent#parseUri(String, int)} to create an
         * Intent that can be launched.
         * <P>
         * Type: TEXT
         * </P>
         */
        static final String INTENT = "intent";

        /**
         * The container holding the favorite
         * <P>
         * Type: INTERGER
         * </P>
         */
        static final String CONTAINER = "container";

        /**
         * The icon is a resource identified by a package name and an integer
         * id.
         */
        static final int CONTAINER_DESKTOP = -100;
        static final int CONTAINER_HOTSEAT = -101;

        /**
         * <P>
         * Type: INTERGER
         * </P>
         */
        static final String SCREEN = "screen";

        /**
         * The X coordinate of the cell holding the favorite (if container is
         * CONTAINER_HOTSEAT or CONTAINER_HOTSEAT)
         * <P>
         * Type: INTERGER
         * </P>
         */
        static final String CELLX = "cellX";

        /**
         * The Y coordinate of the cell holding the favorite (if container is
         * CONTAINER_DESKTOP)
         * <P>
         * Type: INTERGER
         * </P>
         */
        static final String CELLY = "cellY";

        /**
         * <P>
         * Type: INTERGER
         * </P>
         */
        static final String ROTATION = "rotation";

        /**
         * The X span of the cell holding the favorite
         * <P>
         * Type: INTEGER
         * </P>
         */
        static final String SPANX = "spanX";

        /**
         * The Y span of the cell holding the favorite
         * <P>
         * Type: INTEGER
         * </P>
         */
        static final String SPANY = "spanY";

        /**
         * The type of the gesture
         * <P>
         * Type: INTEGER
         * </P>
         */
        static final String ITEM_TYPE = "itemType";

        /**
         * The gesture is an application
         */
        static final int ITEM_TYPE_APPLICATION = 0;

        /**
         * The gesture is an application created shortcut
         */
        static final int ITEM_TYPE_SHORTCUT = 1;

        /**
         * <P>
         * Type: INTEGER NOT NULL DEFAULT -1
         * </P>
         */
        static final String APPWIDGET_ID = "appWidgetId";

        /**
         * <P>
         * Type: BLOB
         * </P>
         */
        static final String DATA = "data";

        /**
         * <P>
         * Type: TEXT
         * </P>
         */
        static final String CONFIG = "config";

        /**
         * <P>
         * Type: TEXT
         * </P>
         */
        static final String PACKAGE_NAME = "packagename";

        /**
         * <P>
         * Type: TEXT
         * </P>
         */
        static final String CLASS_NAME = "classname";

        /**
         * <P>
         * Type: INTEGER
         * </P>
         */
        static final String INTERNAL = "internal";
    }

    static final class Configuration implements BaseShellColumns {

        /**
         * The content:// style URL for this table
         */
        static final Uri CONTENT_URI = Uri.parse("content://" + ShellProvider.AUTHORITY + "/"
                + ShellProvider.TABLE_CONFIGURATION + "?" + ShellProvider.PARAMETER_NOTIFY
                + "=true");

        /**
         * The content:// style URL for this table. When this Uri is used, no
         * notification is sent if the content changes.
         */
        static final Uri CONTENT_URI_NO_NOTIFICATION = Uri.parse("content://"
                + ShellProvider.AUTHORITY + "/" + ShellProvider.TABLE_CONFIGURATION + "?"
                + ShellProvider.PARAMETER_NOTIFY + "=false");

        /**
         * <P>
         * Type: INTERGER
         * </P>
         */
        static final String SCREEN = "screen";

        /**
         * <P>
         * Type: INTERGER
         * </P>
         */
        static final String HOME_PAGE = "homepage";

        /**
         * <P>
         * Type: INTERGER
         * </P>
         */
        static final String EXTRA_SCREEN = "extrascreen";

        /**
         * <P>
         * Type: TEXT
         * </P>
         */
        static final String SCREEN_ORDER = "screenorder";

        /**
         * <P>
         * Type: TEXT
         * </P>
         */
        static final String SCREEN_SCALE = "screenscale";
    }

    static final class Folders implements BaseShellColumns {

        /**
         * The content:// style URL for this table
         */
        static final Uri CONTENT_URI = Uri.parse("content://" + ShellProvider.AUTHORITY + "/"
                + ShellProvider.TABLE_FOLDERS + "?" + ShellProvider.PARAMETER_NOTIFY + "=true");

        /**
         * The content:// style URL for this table. When this Uri is used, no
         * notification is sent if the content changes.
         */
        static final Uri CONTENT_URI_NO_NOTIFICATION = Uri.parse("content://"
                + ShellProvider.AUTHORITY + "/" + ShellProvider.TABLE_FOLDERS + "?"
                + ShellProvider.PARAMETER_NOTIFY + "=false");

        /**
         * <P>
         * Type: INTERGER
         * </P>
         */
        static final String APP_WIDGET_ID = "appWidgetId";

        /**
         * <P>
         * Type: TEXT
         * </P>
         */
        static final String TITLE = "title";

        /**
         * <P>
         * Type: TEXT
         * </P>
         */
        static final String CHILD = "child";
    }

    static final class QuickLaunch implements BaseShellColumns {

        /**
         * The content:// style URL for this table
         */
        static final Uri CONTENT_URI = Uri
                .parse("content://" + ShellProvider.AUTHORITY + "/"
                        + ShellProvider.TABLE_QUICK_LAUNCH + "?" + ShellProvider.PARAMETER_NOTIFY
                        + "=true");

        /**
         * The content:// style URL for this table. When this Uri is used, no
         * notification is sent if the content changes.
         */
        static final Uri CONTENT_URI_NO_NOTIFICATION = Uri.parse("content://"
                + ShellProvider.AUTHORITY + "/" + ShellProvider.TABLE_QUICK_LAUNCH + "?"
                + ShellProvider.PARAMETER_NOTIFY + "=false");

        /**
         * <P>
         * Type: TEXT
         * </P>
         */
        static final String CHILD = "child";
    }

    static final class Theme implements BaseShellColumns {

        /**
         * The content:// style URL for this table
         */
        static final Uri CONTENT_URI = Uri.parse("content://" + ShellProvider.AUTHORITY + "/"
                + ShellProvider.TABLE_THEME + "?" + ShellProvider.PARAMETER_NOTIFY + "=true");

        /**
         * The content:// style URL for this table. When this Uri is used, no
         * notification is sent if the content changes.
         */
        static final Uri CONTENT_URI_NO_NOTIFICATION = Uri.parse("content://"
                + ShellProvider.AUTHORITY + "/" + ShellProvider.TABLE_THEME + "?"
                + ShellProvider.PARAMETER_NOTIFY + "=false");

        /**
         * <P>
         * Type: TEXT
         * </P>
         */
        static final String THEME = "theme";

        /**
         * <P>
         * Type: TEXT
         * </P>
         */
        static final String ICON = "icon";

        /**
         * <P>
         * Type: TEXT
         * </P>
         */
        static final String FOLDER = "folder";

        /**
         * <P>
         * Type: TEXT
         * </P>
         */
        static final String FONT = "font";

        /**
         * <P>
         * Type: INTEGER
         * </P>
         */
        static final String RESET_WALLPAPER = "resetwallpaper";
    }
}
